int main()
{
    int pArray[6];
    int a = 420, b = 420, c = 420, d = 420, e = 420, f = 420;

    for (int i = 0; i < 2520; i++)
    {

        //  change1
        b += a / 8;
        a = a / 8 * 7;
        //   change2
        c += b / 7;
        b = b / 7 * 6;
        // change3
        d += c / 6;
        c = c / 6 * 5;
        // change4
        e += d / 5;
        d = d / 5 * 4;
        // change5
        f += e / 4;
        e = e / 4 * 3;
        // change6
        a += f / 3;
        f = f / 3 * 2;
        if (a == b && b == c && c == d && d == e && e == f)
        {
            break;
        }
    }
}